package BS.dao;

import java.util.HashMap;
import java.util.Map;

public class daofactory {
	private static daofactory factory = new daofactory();

	private Map<String, Object> map = new HashMap<String, Object>();

	private daofactory() {

	}

	public static daofactory getInstance() {
		return factory;
	}

	public caozuoyuanDao getcaozuoyuanDao() {
		caozuoyuanDao dao = (caozuoyuanDao) map.get("caozuoyuanDao");
		if (dao != null) {
			return dao;
		} else {
			dao = new caozuoyuanDao();
			map.put("caozuoyuanDao", dao);
		}
		return dao;
	}

	public guanliyuanDao getguanliyuanDao() {
		guanliyuanDao dao = (guanliyuanDao) map.get("guanliyuanDao");
		if (dao != null) {
			return dao;
		} else {
			dao = new guanliyuanDao();
			map.put("guanliyuan", dao);
		}
		return dao;
	}

	public gdzcDao getgdzcDao() {
		gdzcDao dao = (gdzcDao) map.get("gdzcDao");
		if (dao != null) {
			return dao;
		} else {
			dao = new gdzcDao();
			map.put("gdzcDao", dao);
		}
		return dao;
	}

	public wbwDao getwbwDao() {
		wbwDao dao = (wbwDao) map.get("wbwDao");
		if (dao != null) {
			return dao;
		} else {
			dao = new wbwDao();
			map.put("wbwDao", dao);
		}
		return dao;
	}

}
